.class Lcom/waiqin365/lightapp/syorder/product/a/h;
.super Ljava/lang/Object;

# interfaces
.implements Landroid/view/View$OnClickListener;


# instance fields
.field final synthetic a:Lcom/waiqin365/lightapp/syorder/product/a/l;

.field final synthetic b:Lcom/waiqin365/lightapp/syorder/product/a/a;


# direct methods
.method constructor <init>(Lcom/waiqin365/lightapp/syorder/product/a/a;Lcom/waiqin365/lightapp/syorder/product/a/l;)V
    .locals 0

    iput-object p1, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->b:Lcom/waiqin365/lightapp/syorder/product/a/a;

    iput-object p2, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public onClick(Landroid/view/View;)V
    .locals 11

    const/4 v1, 0x0

    const/4 v10, 0x2

    const/4 v4, 0x1

    const-wide/16 v2, 0x0

    iget-object v0, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v0, v0, Lcom/waiqin365/lightapp/syorder/product/a/l;->k:Landroid/widget/ImageView;

    invoke-virtual {v0}, Landroid/widget/ImageView;->getTag()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/waiqin365/lightapp/syorder/d/b;

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->p:Landroid/widget/LinearLayout;

    invoke-virtual {v5}, Landroid/widget/LinearLayout;->getVisibility()I

    move-result v5

    if-nez v5, :cond_1

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->f:Landroid/widget/TextView;

    const v6, 0x7f02003b

    invoke-virtual {v5, v6}, Landroid/widget/TextView;->setBackgroundResource(I)V

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->p:Landroid/widget/LinearLayout;

    const/16 v6, 0x8

    invoke-virtual {v5, v6}, Landroid/widget/LinearLayout;->setVisibility(I)V

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->f:Landroid/widget/TextView;

    const-string/jumbo v6, "#101010"

    invoke-static {v6}, Landroid/graphics/Color;->parseColor(Ljava/lang/String;)I

    move-result v6

    invoke-virtual {v5, v6}, Landroid/widget/TextView;->setTextColor(I)V

    :goto_0
    const-string/jumbo v5, ""

    iput-object v5, v0, Lcom/waiqin365/lightapp/syorder/d/b;->o:Ljava/lang/String;

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    cmpl-double v5, v6, v2

    if-nez v5, :cond_2

    :cond_0
    :goto_1
    return-void

    :cond_1
    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->f:Landroid/widget/TextView;

    const v6, 0x7f020038

    invoke-virtual {v5, v6}, Landroid/widget/TextView;->setBackgroundResource(I)V

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->p:Landroid/widget/LinearLayout;

    invoke-virtual {v5, v1}, Landroid/widget/LinearLayout;->setVisibility(I)V

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->f:Landroid/widget/TextView;

    const-string/jumbo v6, "#ffffff"

    invoke-static {v6}, Landroid/graphics/Color;->parseColor(Ljava/lang/String;)I

    move-result v6

    invoke-virtual {v5, v6}, Landroid/widget/TextView;->setTextColor(I)V

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->o:Landroid/widget/EditText;

    const-string/jumbo v6, ""

    invoke-virtual {v5, v6}, Landroid/widget/EditText;->setText(Ljava/lang/CharSequence;)V

    goto :goto_0

    :cond_2
    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->h:D

    iget-wide v8, v0, Lcom/waiqin365/lightapp/syorder/d/b;->D:D

    cmpl-double v5, v6, v8

    if-nez v5, :cond_6

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->i:D

    iget-wide v8, v0, Lcom/waiqin365/lightapp/syorder/d/b;->h:D

    cmpg-double v5, v6, v8

    if-gtz v5, :cond_4

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->D:D

    iget-wide v8, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    mul-double/2addr v6, v8

    iget-object v5, v0, Lcom/waiqin365/lightapp/syorder/d/b;->o:Ljava/lang/String;

    invoke-static {v5, v2, v3}, Lcom/fiberhome/gaea/client/d/k;->a(Ljava/lang/String;D)D

    move-result-wide v8

    sub-double/2addr v6, v8

    iput-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->l:D

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->D:D

    iget-wide v8, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    mul-double/2addr v6, v8

    iput-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->k:D

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    cmpl-double v5, v6, v2

    if-nez v5, :cond_5

    :goto_2
    iput-wide v2, v0, Lcom/waiqin365/lightapp/syorder/d/b;->i:D

    iget-object v2, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v2, v2, Lcom/waiqin365/lightapp/syorder/product/a/l;->m:Lcom/waiqin365/lightapp/view/EditTextHasClear;

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->i:D

    invoke-virtual {v3, v6, v7}, Ljava/lang/StringBuilder;->append(D)Ljava/lang/StringBuilder;

    move-result-object v3

    const-string/jumbo v5, ""

    invoke-virtual {v3, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v3

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->m:Lcom/waiqin365/lightapp/view/EditTextHasClear;

    invoke-virtual {v5}, Lcom/waiqin365/lightapp/view/EditTextHasClear;->isEnabled()Z

    move-result v5

    if-nez v5, :cond_3

    move v1, v4

    :cond_3
    invoke-static {v3, v10, v1}, Lcom/waiqin365/lightapp/product/e/b;->b(Ljava/lang/String;IZ)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v2, v1}, Lcom/waiqin365/lightapp/view/EditTextHasClear;->setText(Ljava/lang/CharSequence;)V

    iget-object v1, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v1, v1, Lcom/waiqin365/lightapp/syorder/product/a/l;->g:Landroid/widget/TextView;

    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    const-string/jumbo v3, "\u00a5 "

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->l:D

    invoke-virtual {v3, v6, v7}, Ljava/lang/StringBuilder;->append(D)Ljava/lang/StringBuilder;

    move-result-object v0

    const-string/jumbo v3, ""

    invoke-virtual {v0, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0, v10, v4}, Lcom/waiqin365/lightapp/product/e/b;->b(Ljava/lang/String;IZ)Ljava/lang/String;

    move-result-object v0

    invoke-virtual {v2, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {v1, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    :cond_4
    :goto_3
    iget-object v0, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->b:Lcom/waiqin365/lightapp/syorder/product/a/a;

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/a/a;->b(Lcom/waiqin365/lightapp/syorder/product/a/a;)Lcom/waiqin365/lightapp/syorder/product/a/j;

    move-result-object v0

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->b:Lcom/waiqin365/lightapp/syorder/product/a/a;

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/a/a;->b(Lcom/waiqin365/lightapp/syorder/product/a/a;)Lcom/waiqin365/lightapp/syorder/product/a/j;

    move-result-object v0

    invoke-interface {v0}, Lcom/waiqin365/lightapp/syorder/product/a/j;->a()V

    goto/16 :goto_1

    :cond_5
    iget-wide v2, v0, Lcom/waiqin365/lightapp/syorder/d/b;->l:D

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    div-double/2addr v2, v6

    goto :goto_2

    :cond_6
    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->h:D

    iget-wide v8, v0, Lcom/waiqin365/lightapp/syorder/d/b;->D:D

    cmpl-double v5, v6, v8

    if-lez v5, :cond_4

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->D:D

    iget-wide v8, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    mul-double/2addr v6, v8

    iget-object v5, v0, Lcom/waiqin365/lightapp/syorder/d/b;->o:Ljava/lang/String;

    invoke-static {v5, v2, v3}, Lcom/fiberhome/gaea/client/d/k;->a(Ljava/lang/String;D)D

    move-result-wide v8

    sub-double/2addr v6, v8

    iput-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->l:D

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->D:D

    iget-wide v8, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    mul-double/2addr v6, v8

    iput-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->k:D

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    cmpl-double v5, v6, v2

    if-nez v5, :cond_8

    :goto_4
    iput-wide v2, v0, Lcom/waiqin365/lightapp/syorder/d/b;->i:D

    iget-object v2, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v2, v2, Lcom/waiqin365/lightapp/syorder/product/a/l;->m:Lcom/waiqin365/lightapp/view/EditTextHasClear;

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->i:D

    invoke-virtual {v3, v6, v7}, Ljava/lang/StringBuilder;->append(D)Ljava/lang/StringBuilder;

    move-result-object v3

    const-string/jumbo v5, ""

    invoke-virtual {v3, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v3

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    iget-object v5, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v5, v5, Lcom/waiqin365/lightapp/syorder/product/a/l;->m:Lcom/waiqin365/lightapp/view/EditTextHasClear;

    invoke-virtual {v5}, Lcom/waiqin365/lightapp/view/EditTextHasClear;->isEnabled()Z

    move-result v5

    if-nez v5, :cond_7

    move v1, v4

    :cond_7
    invoke-static {v3, v10, v1}, Lcom/waiqin365/lightapp/product/e/b;->b(Ljava/lang/String;IZ)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v2, v1}, Lcom/waiqin365/lightapp/view/EditTextHasClear;->setText(Ljava/lang/CharSequence;)V

    iget-object v1, p0, Lcom/waiqin365/lightapp/syorder/product/a/h;->a:Lcom/waiqin365/lightapp/syorder/product/a/l;

    iget-object v1, v1, Lcom/waiqin365/lightapp/syorder/product/a/l;->g:Landroid/widget/TextView;

    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    const-string/jumbo v3, "\u00a5 "

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->l:D

    invoke-virtual {v3, v6, v7}, Ljava/lang/StringBuilder;->append(D)Ljava/lang/StringBuilder;

    move-result-object v0

    const-string/jumbo v3, ""

    invoke-virtual {v0, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0, v10, v4}, Lcom/waiqin365/lightapp/product/e/b;->b(Ljava/lang/String;IZ)Ljava/lang/String;

    move-result-object v0

    invoke-virtual {v2, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {v1, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    goto/16 :goto_3

    :cond_8
    iget-wide v2, v0, Lcom/waiqin365/lightapp/syorder/d/b;->l:D

    iget-wide v6, v0, Lcom/waiqin365/lightapp/syorder/d/b;->j:D

    div-double/2addr v2, v6

    goto :goto_4
.end method
